package com.demo;

import com.okhttp.annotations.ApiGenerateService;
import com.okhttp.annotations.ApiResponseHandler;
import okhttp3.ResponseBody;
import retrofit2.Call;
import retrofit2.http.Field;
import retrofit2.http.FormUrlEncoded;
import retrofit2.http.POST;

@ApiGenerateService(ResultBodyHandler.class)
public interface Net2 {

  @FormUrlEncoded
  @POST("city")
  public Call<ResponseBody> getIndexPost(@Field("postTest") String test);

  @ApiResponseHandler(
      handler = ResultHandler2.class,
      genericity = DataBean.class

  )
  @FormUrlEncoded
  @POST("city")
  public Call<Result<DataBean>> getIndexPost2(@Field("postTest") String test);
}
